BIN = process
cc = gcc
OFLAGS = -o
CFLAGS = -c
SRC = $(wildcard *.c)
OBJ = $(SRC:.c=.o)
RM = rm -f

$(BIN) :$(OBJ)
	@$(cc) $(OFLAGS) $@ $^
	@echo "链接 $^ 成为 $@ "
%.o:%.c
	@$(cc) $(CFLAGS)  $<
	@echo "编译 $< 成为 $@ "
.PHONY:clean
clean:
	@$(RM) $(BIN) $(OBJ)
	@echo “清理工程完毕“

